package com.delivery.deliverysystem.service;

import com.delivery.deliverysystem.exception.RException;
import com.delivery.deliverysystem.pojo.DAO.CompanyDTO;
import com.delivery.deliverysystem.pojo.DO.Company;
import com.baomidou.mybatisplus.extension.service.IService;

import java.util.Map;

/**
* @author Administrator
* @description 针对表【company(公司资料表)】的数据库操作Service
* @createDate 2025-01-13 15:37:40
*/
public interface CompanyService extends IService<Company> {

    /**
     * 新增公司
     * @param companyDTO
     * @return
     */
    boolean createCompany(CompanyDTO companyDTO) throws RException;

    /**
     * 编辑公司资料
     * @param companyDTO
     * @return
     */
    boolean updateCompany(String logoPath,CompanyDTO companyDTO) throws Exception;

    /**
     * 根据公司id获取公司信息
     * @param companyId
     * @return
     */
    Company getCompanyById(Integer companyId);

    /**
     * 生成注册码
     * @return
     */
    Map<String, Object> generateCode(String filePath,String companyName) throws RException;

}
